<%--
  Created by IntelliJ IDEA.
  User: Administrator
  Date: 2021/12/9 0009
  Time: 14:20
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>表单</title>
</head>
<body>
<form method="get" action="aaa"/>
    <input type="text" name="text"/>
    <input type="submit" name="submit" value="提交"/>
</form>
<form method="post" action="aaa"/>
    <input type="text" name="text"/>
    <input type="submit" name="submit" value="提交"/>
</form>
<%
    request.getSession().setAttribute("name","WSQ");
    application.setAttribute("name","WSQ");
    Cookie c=new Cookie("name","WSQ");
    c.setMaxAge(600);
    response.addCookie(c);
%>
</body>
</html>
